Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: delete a project even if the current state is destroyed #1413

Merged
merged 11 commits into from
Nov 23, 2023

Conversation

chesedo
Copy link
Contributor

@chesedo chesedo commented Nov 22, 2023

Description of change

Causes the delete command to start up destroyed (stopped) projects to be able to delete them.

How has this been tested? (if applicable)

By making new gateway tests. Use the following steps to run them

USE_PANAMAX=disable make up # To start up the other service on your local environment
SHUTTLE_TESTS_NETWORK=shuttle-dev_user-net cargo test --package shuttle-gateway # to run all the gateway tests

If your tests take too long to run and eventually errors with 503 then make sure your firewall is not blocking any requests. See comments in the code.

Copy link
Contributor

@oddgrd oddgrd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! And the new test setup looks great!

Comment on lines +1388 to +1394
#[test_context(TestProject)]
#[tokio::test]
async fn api_delete_project_that_is_ready(project: &mut TestProject) -> anyhow::Result<()> {
project.router_call(Method::DELETE, "/delete").await;

Ok(())
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean! 😍 Can we apply these utilities for the existing tests as well, and break them up into smaller pieces (looking at you api_create_get_delete_projects)? We can do it in a later PR to not block this for tomorrows release.

Copy link
Contributor Author

@chesedo chesedo Nov 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yip, getting to them in another PR is the plan.... and maybe even adding them to the end of CI after the image builds 😄

@chesedo chesedo merged commit f37a0e8 into main Nov 23, 2023
33 checks passed
@chesedo chesedo deleted the feature/eng-1878-handling-states-destroyed branch November 23, 2023 10:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants